//
//  ViewController.swift
//  SwiftDemos
//
//  Created by 黄旺鑫 on 15/11/9.
//  Copyright © 2015年 黄旺鑫. All rights reserved.
//

import UIKit

class ViewController: UIViewController {

    override func viewDidLoad() {
        super.viewDidLoad()
        // Do any additional setup after loading the view, typically from a nib.
        
        // 创建蒙版
//        addBlurView()
        
        

    }

    override func didReceiveMemoryWarning() {
        super.didReceiveMemoryWarning()
        // Dispose of any resources that can be recreated.
    }
    
    // MARK: - Action
    @IBAction func rightBarButtonAcion(sender: AnyObject) {
        
    }

    // MARK: - 自定义方法
    
    /****************************  蒙版  ****************************/
    
    /**
    *   添加蒙版
    */
    func addBlurView() {
        /* Note: An image has already been placed on the view of this controller */
        
        /* First, create the blur effect with the "Light" style.
        All the styles are defined in UIBlurEffectStyle */
        let blurEffect = UIBlurEffect(style: .Light)
        
        /* Then create the effect view, using the blur effect that
        we just created. The effect is of type UIVisualEffect */
        let blurView = UIVisualEffectView(effect: blurEffect)
        blurView.frame.size = CGSize(width: 200, height: 200)
        blurView.center = view.center
        
        view.addSubview(blurView)
    }
    
    /****************************  弹出框  ****************************/
    lazy var popoverContentController: UINavigationController = {

    }

}

